#pragma once
#include "Tiles.h"
#include "Enemy.h"
#include "Apple.h"
#include "Melon.h"
#include "Banana.h"
#include "Player.h"
#include "CheckPoint.h"
#include "Scenery.h"
#include "PowerUp.h"
#include "DoubleHealth.h"
#include "Disguise.h"
#include "Lever.h"
#include <fstream>
#include <iostream>
#include "SoundPlayer.h"
#include "Highscore.h"

class World
{
public:
	World(void);
	~World(void);
	Tiles* tiles;
	void Draw(HDC bufDC);
	int Update(double x);
	bool canGoThere(int x, int y, int width, int height);

	CEnemy** enemies;
	CPowerUp** powerUps;
	Checkpoint** checkPoints;
	CScenery** scenerys;
	void Init(CPlayer* player, int level, HANDLE *HImage);
	int enemyCount;
	int checkPointCount;
	int sceneryCount;
	int powerUpCount;
	int level;
	bool finishedGame;
	HANDLE *HImage;
	BulletController bullets;

	void LoadLevel1(CPlayer* player);
	void LoadLevel2(CPlayer* player);	

	void Reset();
	int LoadGame(CPlayer* player,HANDLE *hImage);
	void SaveGame(int time, CPlayer* player);

};
